{extend name="common/base" /} {block name="titlekeyword"}
<title>{$content}</title>

{/block} {block name="headjs"}
<script language="javascript">

		var weights = [3, 5, 1, 3, 4, 50];
		weights[2] = '被修改' // 根据下标修改数组中的一个值
		for (var i = 0; i < weights.length; i++) {
			document.writeIn(weights[i]+'<br/>');   //遍历数组元素
		}
	
</script> {/block} {block name="main"}
<h6>内容</h6>
<h6>代码</h6>
<pre>
	&lt;script language="javascript"&gt;
	
	var weights=[3,5,1,3,4,50];
	weights[2] = '被修改' // 根据下标修改数组中的一个值

	for(var i=0;i&lt;weights.length;i++){
	document.writeIn(weights[i]+'br/>');   //遍历数组元素
 }
	
&lt;/script&gt;

	 </pre> {/block}